﻿@model LeadMaster.ViewModels.ViewModelFinancials

<style type="text/css">

#FAEdit label
{
    width:100px;
}

</style>

<legend style="width:300px;">Apply Financial Action</legend>
<div id="FAEdit">
<table class="listtable contactstable" cellspacing="0" cellpadding="0" style="border: thin groove #999999;">
<thead>
<tr>
@foreach (var item in Model.ListLeadResults)
{
    <th>
    @item.Question
    </th>
}
</tr>
</thead>
<tr>
@foreach (var item in Model.ListLeadResults)
{
    <td style="background-color: #CCFF99">
    <label style="font-family: 'Trebuchet MS'; font-size: 10px; color: #666666">@item.Answer</label>
    </td>
}
</tr>
</table>
<hr />
<div>
<label>Introducer</label>
@Html.DisplayFor(m => m.LeadStatus.CallCentre.Contact1)
</div>

<div>
<label>Current Status</label>
@Html.DisplayFor(m => m.LeadStatus.LeadFlag.Description)
</div>

@using (Ajax.BeginForm(
    "Edit", "Financial", null,
    new AjaxOptions
    {
        HttpMethod = "Post",
     }, new { @id = "formEditFinancial" }))
{
    @Html.ValidationSummary(true)

    <fieldset>
    @Html.HiddenFor(m => m.FinanceActions.FinanceActionsID)
    @Html.HiddenFor(m => m.FinanceActions.EarntID)
        <div class="editor-label">
            @Html.Label("Action")
            @Html.DropDownList("FinanceTypesID")
            @Html.ValidationMessageFor(model => model.FinanceActions.FinanceTypesID)
        </div>
        <div style="width:1000px;">
            @Html.Label("Reference / Note")
        </div>
        <div>
            @Html.TextAreaFor(m => m.FinanceActions.Reference, new { @class="notes" })
            @Html.ValidationMessageFor(model => model.FinanceActions.Reference)
        </div>
        <div class="spacer"></div>
        <div>
            <input type="submit" value="Save" />
        </div>
    </fieldset>
}
</div>


@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}

<script type="text/javascript">
    $(document).ready(function () {

        $(".chosen").chosen();

        $(".datepicker").datepicker({
            regional: 'en-GB',
            dateFormat: 'dd/mm/yy'
        });
    });
</script>

